Feat/improve remote installation #228
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
First, thank you for this excellent plugin.
I suggest about improving neovim binary installation and update config.
Currently, this plugin installs the Neovim binary and uploads the config when connecting to a new remote.
However, when the target host is under our control, it likely already has an
nvimcommand and a config under$XDG_CONFIG_HOME/nvim.Therefore, I’ve improved the plugin to reuse those existing installations and configurations instead of reinstalling or reuploading them.
To handle remotes without nvim, I added three policies:
The binary installation and config upload policies can now be configured independently.
In SSH sessions, only system-wide Neovim is available.
To handle hosts without nvim, I added
search_binary_pathsto scan for local binaries and use the absolute path of whichever nvim is found.Additionally, when connecting over SSH the shell may not source files like .bash_profile, so environment variables are not set properly and we can’t use command outside the system.
This can be worked around by piping
.bash_profilebefore running nvim.I added
launch_cmd_prefixso users can prepend custom commands to run before launching nvim.